<extend name="Public/Dialog/Common"/>
<block name="pageContent">
    <div class="bjui-pageContent">
        <form action="__ACTION__" class="pageForm" data-toggle="validate" method="post">
            <input type="hidden" name="id" value="{:I('id')}">
                <table class="table table-condensed table-hover">
                    <tbody>
                    <tr>
                        <td>
                            <label class="control-label x85">分类：</label>
                            <select name="group" data-toggle="selectpicker">
                                <option value="0">其他</option>
                                <volist name="Think.config.CONFIG_GROUP_LIST" id="groupName" key="groupId">
                                    <option value="{$groupId}"
                                    <if condition="$groupId EQ $vo['group'] ">selected</if>
                                    >{$groupName}</option>
                                </volist>
                            </select>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">名称:</label>
                            <input type="text" data-rule="required" size="20" name="name" value="{$vo.name}">
                            <span>用于C函数调用，只能使用英文且不能重复</span>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">标题:</label>
                            <input type="text" data-rule="required" size="20" name="title" value="{$vo.title}">
                            <span>用于后台显示的配置标题</span>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">类型：</label>
                            <select name="type" data-toggle="selectpicker">
                                <volist name="Think.config.CONFIG_TYPE_LIST" id="type">
                                    <option value="{$key}"
                                    <if condition="$key EQ $vo['type'] ">selected</if>
                                    >{$type}
                                    </option>
                                </volist>
                            </select>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">配置值：</label>
                            <textarea cols="20" rows="2" data-toggle="autoheight"
                                      name="value">{$vo.value|default=''}</textarea>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">配置项：</label>
                            <textarea cols="20" rows="2" data-toggle="autoheight"
                                      name="extra">{$vo.extra|default=''}</textarea>
                            <span>如果是枚举型 需要配置该项</span>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">说明：</label>
                            <textarea cols="20" rows="2" data-toggle="autoheight"
                                      name="remark">{$vo.remark|default=''}</textarea>
                            <span>配置详细说明</span>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <label class="control-label x85">排序：</label>
                            <input type="text" size="5" data-toggle="spinner" data-min="0" data-max="100" data-step="1"
                                   data-rule="integer" name="sort" value="{$vo.sort}"></td>
                    </tr>
                    </tbody>
                </table>
        </form>
    </div>
</block>
